-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Immutable js root state #42
Conversation
Thanks for the PR! Made a couple small changes to the README. Also we changed how the store enhancer is applied, so I reverted that. |
This needs to be merged into develop. I'll look into resolving the conflicts later this week, unless you want to rebase it again. |
I can try rebasing, I will let you know if I get stuck |
…ods (eg: redux-persist-immutable) - add config offlineStateLens: with state getter and setter and splitter for offline state vs rest - add config persistAutoRehydrate: to make it possible to inject another autoHydration (eg: redux-persist-immutable) - use offlineStateLens in the middleware and the enhancer - add the new flowtypes for the config - update the README.md
bc2cf5a
to
7109533
Compare
src/index.js
Outdated
config.persist && config.rehydrate | ||
? compose(offlineMiddleware, autoRehydrate()) | ||
: offlineMiddleware; | ||
config.persist && config.rehydrate && config.persistAutoRehydrate |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@wacii Please check that I kept the correct code for this block during the rebase
@wacii I have rebased on top of |
Nifty. I addressed your comment. Everything looks good. Thanks again. |
Addresses issue #37
This patch allows to use
redux-offline
with a root immutable state.These are non breaking changes on top of
v2.1.0
offlineStateLens
: with state getter and setter and splitter foroffline
state vs restpersistAutoRehydrate
: to inject another autoHydration (eg:redux-persist-immutable
)offlineStateLens
in the middleware and the enhancerconfig.persist
flow typeAn auxiliary npm module providing immutable default configs has been published at: https://www.npmjs.com/package/redux-offline-immutable-config
This code has been written together with @Ashmalech